<!DOCTYPE html>
<html class="client-nojs vector-feature-night-mode-disabled vector-feature-language-in-header-enabled vector-feature-language-in-main-page-header-disabled vector-feature-page-tools-pinned-disabled vector-feature-toc-pinned-clientpref-1 vector-feature-main-menu-pinned-disabled vector-feature-limited-width-clientpref-1 vector-feature-limited-width-content-enabled vector-feature-custom-font-size-clientpref-1 vector-feature-appearance-pinned-clientpref-1 vector-sticky-header-enabled" lang="en" dir="ltr"><head>
<meta charset="UTF-8">
<title>Protocol stack</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="canonical" href="https://en.wikipedia.org/wiki/Protocol_stack"> <link href="./mw/ext.cite.styles.css" rel="stylesheet" type="text/css">
<link href="./mw/skins.vector.icons.css" rel="stylesheet" type="text/css">
<link href="./mw/skins.vector.search.codex.styles.css" rel="stylesheet" type="text/css">
<link href="./mw/skins.vector.styles.css" rel="stylesheet" type="text/css">
<link href="./mw/user.styles.css" rel="stylesheet" type="text/css">
<meta name="ResourceLoaderDynamicStyles" content="">
<link rel="stylesheet" type="text/css" href="./mw/site.styles.css">
<link rel="stylesheet" type="text/css" href="./mw/noscript.css">
<link rel="stylesheet" type="text/css" href="./footer.css">
<link rel="stylesheet" type="text/css" href="./vector-2022.css">
</head>
<body class="skin--responsive skin-vector skin-vector-search-vue mediawiki ltr sitedir-ltr mw-hide-empty-elt ns-0 ns-subject page-Protocol_stack rootpage-Protocol_stack skin-vector-2022 action-view">
<div class="mw-page-container">
<div class="mw-page-container-inner">
<div class="mw-content-container">
<main id="content" class="mw-body">
<header class="mw-body-header vector-page-titlebar">
<h1 id="firstHeading" class="firstHeading mw-first-heading">
<span id="openzim-page-title" class="mw-page-title-main"><span class="mw-page-title-main">Protocol stack</span></span>
</h1>
</header>
<a id="top"></a>
<div id="bodyContent" class="vector-body ve-init-mw-desktopArticleTarget-targetContainer" aria-labelledby="firstHeading" data-mw-ve-target-container="">
<div id="mw-content-text" class="mw-body-content mw-content-ltr" lang="en" dir="ltr"><div class="mw-content-ltr mw-parser-output" lang="en" dir="ltr">
<p>The <b>protocol stack</b> or <b>network stack</b> is an <a href="Implementation" title="Implementation">implementation</a> of a <a href="Computer_network" title="Computer network">computer networking</a> <b>protocol suite</b> or <b>protocol family</b>. Some of these terms are used interchangeably but strictly speaking, the <i>suite</i> is the definition of the <a href="Communication_protocol" title="Communication protocol">communication protocols</a>, and the <i>stack</i> is the <a href="Software" title="Software">software</a> implementation of them.<sup id="cite_ref-1" class="reference"><a href="#cite_note-1"><span class="cite-bracket">[</span>1<span class="cite-bracket">]</span></a></sup>
</p><p>Individual protocols within a suite are often designed with a single purpose in mind. This <a href="Modularity_(programming)" class="mw-redirect" title="Modularity (programming)">modularization</a> simplifies design and evaluation. Because each protocol module usually communicates with two others, they are commonly imagined as <a href="Abstraction_layer" title="Abstraction layer">layers</a> in a stack of protocols. The lowest protocol always deals with low-level interaction with the communications hardware. Each higher layer adds additional capabilities. User applications usually deal only with the topmost layers.<sup id="cite_ref-2" class="reference"><a href="#cite_note-2"><span class="cite-bracket">[</span>2<span class="cite-bracket">]</span></a></sup>
</p>
<meta property="mw:PageProp/toc">
<div class="mw-heading mw-heading2"><h2 id="General_protocol_suite_description">General protocol suite description</h2></div>
<pre> T ~ ~ ~ T
[A] [B]_____[C]
</pre>
<p>Imagine three computers: <i>A</i>, <i>B</i>, and <i>C</i>. <i>A</i> and <i>B</i> both have radio equipment and can communicate via the airwaves using a suitable network protocol (such as <a href="IEEE_802.11" title="IEEE 802.11">IEEE 802.11</a>). <i>B</i> and <i>C</i> are connected via a cable, using it to exchange data (again, with the help of a protocol, for example <a href="Point-to-Point_Protocol" title="Point-to-Point Protocol">Point-to-Point Protocol</a>). However, neither of these two protocols will be able to transport information from <i>A</i> to <i>C</i>, because these computers are conceptually on different networks. An <a href="Internetworking" title="Internetworking">inter-network</a> protocol is required to connect them.
</p><p>One could combine the two protocols to form a powerful third, mastering both cable and wireless transmission, but a different super-protocol would be needed for each possible combination of protocols. It is easier to leave the base protocols alone and design a protocol that can work on top of any of them (the <a href="Internet_Protocol" title="Internet Protocol">Internet Protocol</a> is an example). This will make two stacks of two protocols each. The inter-network protocol will communicate with each of the base protocols in their simpler language; the base protocols will not talk directly to each other.
</p><p>A request on computer <i>A</i> to send a chunk of data to <i>C</i> is taken by the upper protocol, which (through whatever means) knows that <i>C</i> is reachable through <i>B</i>. It, therefore, instructs the wireless protocol to transmit the data packet to <i>B</i>. On this computer, the lower layer handlers will pass the packet up to the inter-network protocol, which, on recognizing that <i>B</i> is not the final destination, will again invoke lower-level functions. This time, the cable protocol is used to send the data to <i>C</i>. There, the received packet is again passed to the upper protocol, which (with <i>C</i> being the destination) will pass it on to a higher protocol or application on <i>C</i>.
</p><p>In practical implementation, protocol stacks are often divided into three major sections: media, transport, and applications. A particular <a href="Operating_system" title="Operating system">operating system</a> or platform will often have two well-defined software interfaces: one between the media and transport layers, and one between the transport layers and applications. The media-to-transport interface defines how transport protocol software makes use of particular media and hardware types and is associated with a <a href="Device_driver" title="Device driver">device driver</a>. For example, this interface level would define how <a href="TCP/IP" class="mw-redirect" title="TCP/IP">TCP/IP</a> transport software would talk to the <a href="Network_interface_controller" title="Network interface controller">network interface controller</a>. Examples of these interfaces include <a href="Open_Data-Link_Interface" title="Open Data-Link Interface">ODI</a> and <a href="Network_Driver_Interface_Specification" title="Network Driver Interface Specification">NDIS</a> in the <a href="Microsoft_Windows" title="Microsoft Windows">Microsoft Windows</a> and <a href="DOS" title="DOS">DOS</a> environment. The application-to-transport interface defines how application programs make use of the transport layers. For example, this interface level would define how a <a href="Web_browser" title="Web browser">web browser</a> program would talk to TCP/IP transport software. Examples of these interfaces include <a href="Berkeley_sockets" title="Berkeley sockets">Berkeley sockets</a> and System V <a href="STREAMS" title="STREAMS">STREAMS</a> in <a href="Unix-like" title="Unix-like">Unix-like</a> environments, and <a href="Winsock" title="Winsock">Winsock</a> for Microsoft Windows.
</p>
<div class="mw-heading mw-heading2"><h2 id="Examples">Examples</h2></div>
<table class="wikitable" border="1">
<caption>Example protocol stack and corresponding layers
</caption>
<tbody><tr>
<th>Protocol
</th>
<th>Layer
</th></tr>
<tr>
<td><a href="HTTP" title="HTTP">HTTP</a>
</td>
<td><a href="Application_layer" title="Application layer">Application</a>
</td></tr>
<tr>
<td><a href="Transmission_Control_Protocol" title="Transmission Control Protocol">TCP</a>
</td>
<td><a href="Transport_layer" title="Transport layer">Transport</a>
</td></tr>
<tr>
<td><a href="Internet_Protocol" title="Internet Protocol">IP</a>
</td>
<td><a href="Internet_layer" title="Internet layer">Internet</a> or <a href="Network_layer" title="Network layer">network</a>
</td></tr>
<tr>
<td><a href="Ethernet" title="Ethernet">Ethernet</a>
</td>
<td><a href="Link_layer" title="Link layer">Link</a> or <a href="Data_link_layer" title="Data link layer">data link</a>
</td></tr>
<tr>
<td><a href="IEEE_802.3ab" class="mw-redirect" title="IEEE 802.3ab">IEEE 802.3ab</a>
</td>
<td><a href="Physical_layer" title="Physical layer">Physical</a>
</td></tr></tbody></table>
<div class="mw-heading mw-heading2"><h2 id="Spanning_layer">Spanning layer</h2></div>
<p>An important feature of many communities of interoperability based on a common protocol stack is a <b>spanning layer</b>, a term coined by <a href="David_D._Clark" title="David D. Clark">David Clark</a><sup id="cite_ref-3" class="reference"><a href="#cite_note-3"><span class="cite-bracket">[</span>3<span class="cite-bracket">]</span></a></sup>
</p>
<blockquote><p>Certain protocols are designed with the specific purpose of bridging differences at the lower layers, so that common agreements are not required there. Instead, the layer provides the definitions that permit translation to occur between a range of services or technologies used below. Thus, in somewhat abstract terms, at and above such a layer common standards contribute to interoperation, while below the layer translation is used. Such a layer is called a <i>spanning layer</i> in this paper. As a practical matter, real interoperation is achieved by the definition and use of effective spanning layers. But there are many different ways that a spanning layer can be crafted.</p></blockquote>
<p>In the Internet protocol stack, the <a href="Internet_Protocol_Suite" class="mw-redirect" title="Internet Protocol Suite">Internet Protocol Suite</a> constitutes a spanning layer that defines a <a href="Best-effort_service" class="mw-redirect" title="Best-effort service">best-effort service</a> for global routing of <a href="Datagrams" class="mw-redirect" title="Datagrams">datagrams</a> at <a href="Layer_3" class="mw-redirect" title="Layer 3">Layer 3</a>. The <a href="Internet" title="Internet">Internet</a> is the community of <a href="Interoperation" title="Interoperation">interoperation</a> based on this spanning layer.
</p>
<div class="mw-heading mw-heading2"><h2 id="See_also">See also</h2></div>
<ul><li><a href="Cross-layer_optimization" title="Cross-layer optimization">Cross-layer optimization</a></li>
<li><a href="DECnet" title="DECnet">DECnet</a></li>
<li><a href="Hierarchical_internetworking_model" title="Hierarchical internetworking model">Hierarchical internetworking model</a></li>
<li><a href="Protocol_Wars" title="Protocol Wars">Protocol Wars</a></li>
<li><a href="Recursive_Internetwork_Architecture" title="Recursive Internetwork Architecture">Recursive Internetwork Architecture</a></li>
<li><a href="Service_layer" title="Service layer">Service layer</a></li>
<li><a href="Signalling_System_No._7" title="Signalling System No. 7">Signalling System No. 7</a></li>
<li><a href="Systems_Network_Architecture" title="Systems Network Architecture">Systems Network Architecture</a></li>
<li><a href="Wireless_Application_Protocol" title="Wireless Application Protocol">Wireless Application Protocol</a></li>
<li><a href="X.25" title="X.25">X.25</a></li></ul>
<div class="mw-heading mw-heading2"><h2 id="References">References</h2></div>
<div class="mw-references-wrap"><ol class="references">
<li id="cite_note-1"><span class="mw-cite-backlink"><b><a href="#cite_ref-1">^</a></b></span> <span class="reference-text"><style data-mw-deduplicate="TemplateStyles:r1238218222">
/* start https://en.wikipedia.org/ */
.mw-parser-output cite.citation{font-style:inherit;word-wrap:break-word}.mw-parser-output .citation q{quotes:"\"""\"""'""'"}.mw-parser-output .citation:target{background-color:rgba(0,127,255,0.133)}.mw-parser-output .id-lock-free.id-lock-free a{background:url("./mw/Lock-green.svg")right 0.1em center/9px no-repeat}.mw-parser-output .id-lock-limited.id-lock-limited a,.mw-parser-output .id-lock-registration.id-lock-registration a{background:url("./mw/Lock-gray-alt-2.svg")right 0.1em center/9px no-repeat}.mw-parser-output .id-lock-subscription.id-lock-subscription a{background:url("./mw/Lock-red-alt-2.svg")right 0.1em center/9px no-repeat}.mw-parser-output .cs1-ws-icon a{background:url("./mw/Wikisource-logo.svg")right 0.1em center/12px no-repeat}body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-free a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-limited a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-registration a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-subscription a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .cs1-ws-icon a{background-size:contain;padding:0 1em 0 0}.mw-parser-output .cs1-code{color:inherit;background:inherit;border:none;padding:inherit}.mw-parser-output .cs1-hidden-error{display:none;color:var(--color-error,#d33)}.mw-parser-output .cs1-visible-error{color:var(--color-error,#d33)}.mw-parser-output .cs1-maint{display:none;color:#085;margin-left:0.3em}.mw-parser-output .cs1-kern-left{padding-left:0.2em}.mw-parser-output .cs1-kern-right{padding-right:0.2em}.mw-parser-output .citation .mw-selflink{font-weight:inherit}@media screen{.mw-parser-output .cs1-format{font-size:95%}html.skin-theme-clientpref-night .mw-parser-output .cs1-maint{color:#18911f}}@media screen and (prefers-color-scheme:dark){html.skin-theme-clientpref-os .mw-parser-output .cs1-maint{color:#18911f}}
/* end https://en.wikipedia.org/ */
</style><cite class="citation web cs1"><a rel="nofollow" class="external text" href="http://www.webopedia.com/TERM/P/protocol_stack.html">"What is a protocol stack?"</a>. WEBOPEDIA. 24 September 1997<span class="reference-accessdate">. Retrieved <span class="nowrap">2010-02-21</span></span>. <q>A [protocol stack is a] set of network protocol layers that work together. The <a href="OSI_Reference_Model" class="mw-redirect" title="OSI Reference Model">OSI Reference Model</a> that defines seven protocol layers is often called a stack, as is the set of TCP/IP protocols that define communication over the Internet.</q></cite></span>
</li>
<li id="cite_note-2"><span class="mw-cite-backlink"><b><a href="#cite_ref-2">^</a></b></span> <span class="reference-text"><cite id="CITEREFGeorg_N._Strauß2010" class="citation web cs1">Georg N. Strauß (2010-01-09). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20120320162240/http://www.ika-reutte.at/elearning/OSI_Model.doc">"The OSI Model, Part 10. The Application Layer"</a>. Ika-Reutte. Archived from <a rel="nofollow" class="external text" href="http://www.ika-reutte.at/elearning/OSI_Model.doc">the original</a> on 2012-03-20<span class="reference-accessdate">. Retrieved <span class="nowrap">2010-02-21</span></span>. <q>The Application layer is the topmost layer of the OSI model, and it provides services that directly support user applications, such as database access, e-mail, and file transfers.</q></cite></span>
</li>
<li id="cite_note-3"><span class="mw-cite-backlink"><b><a href="#cite_ref-3">^</a></b></span> <span class="reference-text"><cite id="CITEREFDavid_Clark1997" class="citation book cs1">David Clark (1997). <i>Interoperation, Open Interfaces, and Protocol Architecture</i>. National Research Council. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a> <bdi>9780309060363</bdi>.</cite> <span class="cs1-visible-error citation-comment"><code class="cs1-code">{{cite book}}</code>: </span><span class="cs1-visible-error citation-comment"><code class="cs1-code">|work=</code> ignored (help)</span></span>
</li>
</ol></div></div><!--htdig_noindex--><div><div class="zim-footer">
This article is issued from <a class="external text" title="Last edited on 2025-07-28" href="https://en.wikipedia.org/wiki/?title=Protocol_stack&oldid=1302938912">Wikipedia</a>. The text is available under <a class="external text" href="https://creativecommons.org/licenses/by-sa/4.0/deed.en">Creative Commons Attribution-Share Alike 4.0</a> unless otherwise noted. Additional terms may apply for the media files.
</div>
</div><!--/htdig_noindex--></div>
</div>
</main>
</div>
</div>
</div>
</body></html>